<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <button id="btn">点</button>
    <input type="text" id="out">
</body>
<script>
    /* var i , sum = 0;
    i = 1;

    btn.onclick = function(){
        while(i <= 100)
        {
            sum = sum + i;
            i++;
        }
        out.value = sum;

        do
        { 
            sum = sum + i;
            i++;
        }while(i <= 100);
        out.value = sum;
    } */
    var three = null;
    var seven = null;
    var a = 1;
    
    btn.onclick = function(){
        while(a <= 100)
        {
            
        }
    }
</script>
</html>